package ltd.rycloud.tms.entity;

import javax.persistence.Basic;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;

/***
 * @author     ：RYCloud.ltd ZhangLongBiao
 * @date       ：Created in 2019/6/24 2:23
 * @description：
 * @modified By：
 * @version: $
 *山东如翼云计算科技有限公司  张龙彪  15169994844
 ***/
@Entity
public class Budget {
    private int budgetId;
    private String title;
    private Double ysje;
    private Double hfje;
    private String ysyear;

    @Id
    @Column(name = "budget_id")
    public int getBudgetId() {
        return budgetId;
    }

    public void setBudgetId(int budgetId) {
        this.budgetId = budgetId;
    }

    @Basic
    @Column(name = "title")
    public String getTitle() {
        return title;
    }

    public void setTitle(String title) {
        this.title = title;
    }

    @Basic
    @Column(name = "ysje")
    public Double getYsje() {
        return ysje;
    }

    public void setYsje(Double ysje) {
        this.ysje = ysje;
    }

    @Basic
    @Column(name = "hfje")
    public Double getHfje() {
        return hfje;
    }

    public void setHfje(Double hfje) {
        this.hfje = hfje;
    }

    @Basic
    @Column(name = "ysyear")
    public String getYsyear() {
        return ysyear;
    }

    public void setYsyear(String ysyear) {
        this.ysyear = ysyear;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;

        Budget budget = (Budget) o;

        if (budgetId != budget.budgetId) return false;
        if (title != null ? !title.equals(budget.title) : budget.title != null) return false;
        if (ysje != null ? !ysje.equals(budget.ysje) : budget.ysje != null) return false;
        if (hfje != null ? !hfje.equals(budget.hfje) : budget.hfje != null) return false;
        if (ysyear != null ? !ysyear.equals(budget.ysyear) : budget.ysyear != null) return false;

        return true;
    }

    @Override
    public int hashCode() {
        int result = budgetId;
        result = 31 * result + (title != null ? title.hashCode() : 0);
        result = 31 * result + (ysje != null ? ysje.hashCode() : 0);
        result = 31 * result + (hfje != null ? hfje.hashCode() : 0);
        result = 31 * result + (ysyear != null ? ysyear.hashCode() : 0);
        return result;
    }
}
